<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ page import="DAO.GroundBookDao"%>
<%@ page import="VO.GroundBook"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<title>查看所有预约信息</title>
<link rel="stylesheet" type="text/css" href="css/public.css">
<link rel="stylesheet" type="text/css" href="css/ground_book_all.css">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<!--
  <link rel="stylesheet" type="text/css" href="styles.css">
  -->
</head>
<body>
	<div id="mainbody">
		<div id="title">所有预约信息</div>
		<%	ArrayList groundbook = null;
			GroundBookDao gbdao = new GroundBookDao();
			groundbook = gbdao.queryAllGroundBook();//调用queryAllGroundBook()方法%>
		<table border=2>
			<tr class="title">
				<td>预约编号</td>
				<td>球场名称</td>
				<td>账户</td>
				<td>日期</td>
				<td>时间段</td>
				<td>状态</td>
			</tr>
			<%			for (int i = 0; i < groundbook.size(); i++) {
					GroundBook gbook = (GroundBook) groundbook.get(i);//类型转换			%>
			<tr>
				<td><%=gbook.getBid()%></td>
				<td><%=gbook.getGname()%></td>
				<td><%=gbook.getAccount()%></td>
				<td><%=gbook.getDay()%></td>
				<td><%=gbook.getTime()%></td>
				<td><%=gbook.getBstatus()%></td>

			</tr>
			<%
				}
			%>
		</table>

	</div>
</body>
</html>
